<?php

namespace App\Models\Enum;

/**
 * 充值补偿状态
 */
class RechargeStatus
{
    const UNCHECK = 1;
    const CHECKING = 2;
    const AGREE = 3;
    const BAN = 4;
    const CANCEL = 5;

    public static function get($type)
    {
        switch ($type) {
            case self::UNCHECK:
                return '未审核';
            case self::CHECKING:
                return '审核中';
            case self::AGREE:
                return '同意';
            case self::BAN:
                return '不同意';
            case self::CANCEL:
                return '撤销';
            default:
                return '类型未定义';
        }
    }

    public static function getAll()
    {
        return [
            self::UNCHECK => self::get(self::UNCHECK),
            self::CHECKING => self::get(self::CHECKING),
            self::AGREE => self::get(self::AGREE),
            self::BAN => self::get(self::BAN),
            self::CANCEL => self::get(self::CANCEL),
        ];
    }
}